data(plasma)
plasma |>
filter(alcohol<200) -> plasmaPractical session 2
NHMRC Clinical Trials Centre, University of Sydney
gillian.heller@sydney.edu.au
df AIC
m.step 18.08183 5217.076
m.lasso.adaptive2 5.00000 5228.318
m.lasso 5.00000 5242.114
******************************************************************
Summary of the Quantile Residuals
mean = -0.001549316
variance = 1.003283
coef. of skewness = 0.005100953
coef. of kurtosis = 2.990256
Filliben correlation coefficient = 0.9976408
******************************************************************
******************************************************************
Summary of the Quantile Residuals
mean = -0.0004199963
variance = 1.003924
coef. of skewness = 0.007600763
coef. of kurtosis = 2.988339
Filliben correlation coefficient = 0.9980725
******************************************************************
******************************************************************
Summary of the Quantile Residuals
mean = -0.0009406445
variance = 1.003896
coef. of skewness = 0.01505683
coef. of kurtosis = 3.005563
Filliben correlation coefficient = 0.9976675
******************************************************************
number of missing points from plot= 0 out of 52
number of missing points from plot= 0 out of 54
number of missing points from plot= 0 out of 52
number of missing points from plot= 0 out of 51
number of missing points from plot= 0 out of 53
number of missing points from plot= 0 out of 52
******************************************************************
Family: c("BCTo", "Box-Cox-t-orig.")
Call: gamlss(formula = betadiet ~ log(fiber), family = BCTo,
data = plasma, trace = FALSE)
Fitting method: RS()
------------------------------------------------------------------
Mu link function: log
Mu Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 5.37324 0.18403 29.20 <2e-16 ***
log(fiber) 0.86470 0.07384 11.71 <2e-16 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
------------------------------------------------------------------
Sigma link function: log
Sigma Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) -0.66598 0.06218 -10.71 <2e-16 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
------------------------------------------------------------------
Nu link function: identity
Nu Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 0.16413 0.09424 1.742 0.0826 .
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
------------------------------------------------------------------
Tau link function: log
Tau Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 2.6357 0.6472 4.072 5.92e-05 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
------------------------------------------------------------------
No. of observations in the fit: 314
Degrees of Freedom for the fit: 5
Residual Deg. of Freedom: 309
at cycle: 7
Global Deviance: 5218.318
AIC: 5228.318
SBC: 5247.065
******************************************************************
log(fiber) is to multiply median betadiet by \exp(0.86470) = 2.37OR (better)
fiber is a multiplicative increase in median betadiet of 1.1^{0.86470}=1.086, i.e. 8.6% increase.What is the effect of cholesterol on the distribution of betadiet?
We cannot evaluate the effect of cholesterol on \mu in isolation, because cholesterol simultaneously affects \sigma
We need to look at the effect of cholesterol on the whole distribution of betadiet
betadiet for
smokstat = 1 (never smoked)fat = 54 (~ 1st quartile)fiber = 15 (~ 3rd quartile)cholesterol = 100, 200, 300, 400, 500betadiet for
smokstat = 3 (current smoker)fat = 95 (~ 3rd quartile)fiber = 9 (~ 1st quartile)cholesterol = 100, 200, 300, 400, 500pe_pdf(m.step, term="cholesterol",
scenario = list("smokstat"=3, "fat"=95, "fiber"=9),
x.values = c(100, 200, 300, 400, 500),
xlim = c(0, 7500))Practical 2